<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
    <head>
        <title>Test Index2</title>
        <%= stylesheet_link_tag "../javascripts/ext/resources/css/ext-all.css" %>
        <%= javascript_include_tag "ext/adapter/prototype/prototype.js" %>
        <%= javascript_include_tag "ext/adapter/prototype/scriptaculous.js" %>
        <%= javascript_include_tag "ext/adapter/prototype/effects.js" %>
        <%= javascript_include_tag "ext/adapter/prototype/ext-prototype-adapter.js" %>
        <%= javascript_include_tag "ext/ext-all-debug.js" %>
        <%= javascript_include_tag "ext/build/locale/ext-lang-zh_CN.js" %>
    </head>
    <body>
        <div id="container">
            <div id="toolbar">
            </div>
        </div>
        <script>
            /*
             * Ext JS Library 2.0.2
             * Copyright(c) 2006-2008, Ext JS, LLC.
             * licensing@extjs.com
             *
             * http://extjs.com/license
             */
            Ext.onReady(function(){
                var main_business_menu = new Ext.menu.Menu({
                    id: 'mainBusinessMenu',
                    items: [{
                        text: '来电显示',
                        id: 'fuckyou',
                        handler: onItemClick
                    }, {
                        text: '出票',
                        handler: onItemClick
                    }, {
                        text: '出保险',
                        handler: onItemClick
                    }, {
                        text: '打印送票单',
                        handler: onItemClick
                    }, {
                        text: '订单收款',
                        handler: onItemClick
                    }, {
                        text: '打印行程单',
                        handler: onItemClick
                    }, {
                        text: '出保险',
                        handler: onItemClick
                    }, {
                        text: '定票',
                        handler: onItemClick
                    }, '-', {
                        text: '退出系统',
                        handler: onItemClick
                    }]
                });
                
                var order_menu = new Ext.menu.Menu({
                    id: 'orderMenu',
                    items: [{
                        text: '来电显示',
                        id: 'fuckyou',
                        handler: onItemClick
                    }, {
                        text: '出票',
                        handler: onItemClick
                    }, {
                        text: '出保险',
                        handler: onItemClick
                    }, {
                        text: '打印送票单',
                        handler: onItemClick
                    }, {
                        text: '订单收款',
                        handler: onItemClick
                    }, {
                        text: '打印行程单',
                        handler: onItemClick
                    }, {
                        text: '出保险',
                        handler: onItemClick
                    }, {
                        text: '定票',
                        handler: onItemClick
                    }, '-', {
                        text: '退出系统',
                        handler: onItemClick
                    }]
                });
				
				var system_menu = new Ext.menu.Menu({
                    id: 'systemMenu',
                    items: [{
                        text: '来电显示',
                        id: 'fuckyou',
                        handler: onItemClick
                    }, {
                        text: '出票',
                        handler: onItemClick
                    }, {
                        text: '出保险',
                        handler: onItemClick
                    }, {
                        text: '打印送票单',
                        handler: onItemClick
                    }, {
                        text: '订单收款',
                        handler: onItemClick
                    }, {
                        text: '打印行程单',
                        handler: onItemClick
                    }, {
                        text: '出保险',
                        handler: onItemClick
                    }, {
                        text: '定票',
                        handler: onItemClick
                    }, '-', {
                        text: '退出系统',
                        handler: onItemClick
                    }]
                });
				
				var tools_menu = new Ext.menu.Menu({
                    id: 'toolsMenu',
                    items: [{
                        text: '来电显示',
                        id: 'fuckyou',
                        handler: onItemClick
                    }, {
                        text: '出票',
                        handler: onItemClick
                    }, {
                        text: '出保险',
                        handler: onItemClick
                    }, {
                        text: '打印送票单',
                        handler: onItemClick
                    }, {
                        text: '订单收款',
                        handler: onItemClick
                    }, {
                        text: '打印行程单',
                        handler: onItemClick
                    }, {
                        text: '出保险',
                        handler: onItemClick
                    }, {
                        text: '定票',
                        handler: onItemClick
                    }, '-', {
                        text: '退出系统',
                        handler: onItemClick
                    }]
                });
				
				var report_menu = new Ext.menu.Menu({
                    id: 'reportMenu',
                    items: [{
                        text: '来电显示',
                        id: 'fuckyou',
                        handler: onItemClick
                    }, {
                        text: '出票',
                        handler: onItemClick
                    }, {
                        text: '出保险',
                        handler: onItemClick
                    }, {
                        text: '打印送票单',
                        handler: onItemClick
                    }, {
                        text: '订单收款',
                        handler: onItemClick
                    }, {
                        text: '打印行程单',
                        handler: onItemClick
                    }, {
                        text: '出保险',
                        handler: onItemClick
                    }, {
                        text: '定票',
                        handler: onItemClick
                    }, '-', {
                        text: '退出系统',
                        handler: onItemClick
                    }]
                });
				var ticket_menu = new Ext.menu.Menu({
                    id: 'ticketMenu',
                    items: [{
                        text: '来电显示',
                        id: 'fuckyou',
                        handler: onItemClick
                    }, {
                        text: '出票',
                        handler: onItemClick
                    }, {
                        text: '出保险',
                        handler: onItemClick
                    }, {
                        text: '打印送票单',
                        handler: onItemClick
                    }, {
                        text: '订单收款',
                        handler: onItemClick
                    }, {
                        text: '打印行程单',
                        handler: onItemClick
                    }, {
                        text: '出保险',
                        handler: onItemClick
                    }, {
                        text: '定票',
                        handler: onItemClick
                    }, '-', {
                        text: '退出系统',
                        handler: onItemClick
                    }]
                });
				var help_menu = new Ext.menu.Menu({
                    id: 'helpMenu',
                    items: [{
                        text: '关于',
                        handler: onItemClick
                    }]
                });
                var tb = new Ext.Toolbar();
                tb.render('toolbar');
                
                tb.add({
                    text: '业务系统',
                    menu: main_business_menu // assign menu by instance
                }, {
                    text: '订单管理',
                    menu: order_menu // assign menu by instance
                }, {
                    text: '系统管理',
                    menu: system_menu // assign menu by instance
                }, {
                    text: '相关工具',
                    menu: tools_menu // assign menu by instance
                }, {
                    text: '统计报表',
                    menu: report_menu // assign menu by instance
                }, {
                    text: '票证管理',
                    menu: ticket_menu // assign menu by instance
                }, {
                    text: '帮助',
                    menu: help_menu // assign menu by instance
                });
                
                function onItemClick(item){
					if(item.text=="关于"){
						Ext.MessageBox.alert('关于', '制作：奇思管理咨询有限公司<br><br>开发人员：Jerry,Mike');
					}
                    //Ext.example.msg('Menu Click', 'You clicked the "{0}" menu item.', item.text);
                }
            });
        </script>
    </body>
</html>
